<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html lang="en">

<head>
<title>班级信息</title>
<meta name="keywords" content="迎新管理系统" />

<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="本系统基于TP3.2开发，感谢开源">
<link rel="shortcut icon" href="favicon.ico">
<link href="/orientation/Public/css/bootstrap.min14ed.css?v=3.3.6" rel="stylesheet">
<link href="/orientation/Public/css/font-awesome.min93e3.css?v=4.4.0" rel="stylesheet">
<link href="/orientation/Public/css/animate.min.css" rel="stylesheet">
<link href="/orientation/Public/css/style.min862f.css?v=4.1.0" rel="stylesheet">
<link href="/orientation/Public/css/plugins/iCheck/custom.css" rel="stylesheet">
<link href="/orientation/Public/css/iconfont.css" rel="stylesheet"/>

    <!--[if lt IE 9]>
<meta http-equiv="refresh" content="0;ie.html" />
<![endif]-->
</head>

<body class="gray-bg">
<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-content">
                    <div method="get" class="form-horizontal">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">班级编号</label>
                            <div class="col-sm-10">
                                <input type="text" class="form-control" value="<?php echo ($class['classnum']); ?>" id="classnum">
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">班级名称</label>
                            <div class="col-sm-10">
                                <input type="text" class="form-control" value="<?php echo ($class['classname']); ?>" id="classname">
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">班级人数</label>
                            <div class="col-sm-10">
                                <input type="text" class="form-control" readonly value="<?php echo ($class['classsize']); ?>" id="classsize">
                            </div>
                        </div>
                        
                        <button id="subbtn" class="btn btn-w-m btn-info" type="button" data-id="<?php echo ($class['classnum']); ?>">确认提交</button>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
</body>

<script src="/orientation/Public/js/jquery.min.js?v=2.1.4"></script>
<script src="/orientation/Public/js/bootstrap.min.js?v=3.3.6"></script>
<script src="/orientation/Public/js/content.min.js?v=1.0.0"></script>
<script src="/orientation/Public/js/plugins/iCheck/icheck.min.js"></script>
<script>
    $(document).ready(function(){$(".i-checks").iCheck({checkboxClass:"icheckbox_square-green",radioClass:"iradio_square-green",})});
</script>
<script type="text/javascript" src="http://tajs.qq.com/stats?sId=9051096" charset="UTF-8"></script>
<script>
    $('#subbtn').on('click',function () {
        var btn = $(this);
        var classnum = btn.data('id');
        var classname = $('#classname').val();
        var classsize = $('#classsize').val();
        var param = {
        	classnum:classnum,
            classname:classname,
            classsize:classsize
        };
        console.log(param);
        var url = "<?php echo U('Superadmin/classsave');?>";
        $.ajax({
            url: url,
            data: param,
            dataType: 'json',
            type: 'post',
            success: function (data) {
                alert(data.info);
                if (data.status == 1) {
                }
            },
            error: function () {
                alert('操作失败');
            }
        })
    })
</script>
</html>